package com.accloud.service;

public class ACException extends Exception {
    public static int ABLELINK_ERROR1 = 1960;
    public static int ABLELINK_ERROR2 = 1961;
    public static int ABLELINK_ERROR3 = 1962;
    public static int ABLELINK_ERROR4 = 1963;
    public static int CHECK_CRC_FAILURE = 1984;
    public static int CONNECTED_FIRST = 1985;
    public static int ENTRY_EMPTY = 1990;
    public static int INTERNAL_ERROR = 1999;
    public static int INTERNET_ERROR = 1998;
    public static int INVALID_PARAMETERS = 1991;
    public static int INVALID_PAYLOAD = 1989;
    public static int LOCAL_DEVICE_OFFLINE = 1988;
    public static int MARSHAL_ERROR = 1995;
    public static int NO_LOGIN = 1992;
    public static int NO_NETWORK_AVAILABLE = 1987;
    public static int NO_WIFI_CONNECTED = 1986;
    public static int TIMEOUT = 1993;
    public static int WRONG_PAYLOAD_FORMAT = 1997;
    protected String description;
    protected int errorCode;

    public ACException(int errorCode2) {
        this.errorCode = errorCode2;
    }

    public ACException(int errorCode2, String detailMessage) {
        super(detailMessage);
        this.errorCode = errorCode2;
    }

    public ACException(int errorCode2, String detailMessage, String description2) {
        super(detailMessage);
        this.errorCode = errorCode2;
        this.description = description2;
    }

    public ACException(int errorCode2, Throwable throwable) {
        super(throwable);
        this.errorCode = errorCode2;
    }

    public int getErrorCode() {
        return this.errorCode;
    }

    public String getDescription() {
        return this.description;
    }

    @Override // java.lang.Throwable, java.lang.Object
    public String toString() {
        if (this.description == null) {
            return "ACException{errorCode=" + this.errorCode + ", message='" + getMessage() + "'}";
        }
        return "ACException{errorCode=" + this.errorCode + ", message='" + getMessage() + "', description='" + this.description + "'}";
    }
}
